home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 1 (Walnut Creek)
/
Aminet - June 1993 [Walnut Creek].iso
/
usenet
/
sources
/
volume2
/
fun
/
nethack.d1
< prev
next >
Wrap
Text File
|
1988-12-02
|
51KB
|
1,835 lines
Path: xanth!nic.MR.NET!hal!cwjcc!gatech!rutgers!mit-eddie!ll-xn!adelie!infinet!ulowell!page
From: page@swan.ulowell.edu (Bob Page)
Newsgroups: comp.sources.amiga
Subject: v02i070: nethack - D&D-like game (amiga diffs), Part01/04
Message-ID: <10401@swan.ulowell.edu>
Date: 1 Dec 88 23:42:39 GMT
Organization: University of Lowell, Computer Science Dept.
Lines: 1824
Approved: page@swan.ulowell.edu
Submitted-by: u211344@hnykun11.bitnet (Olaf 'Rhialto' Seibert)
Posting-number: Volume 2, Issue 70
Archive-name: fun/nethack.d1
[combine all four of these diff files together into one file, then
feed that file to the 'patch' program (posted to comp.sources.amiga a
long time ago) to produce "amigafied" nethack sources. ..Bob]
# This is a shell archive.
# Remove everything above and including the cut line.
# Then run the rest of the file through sh.
#----cut here-----cut here-----cut here-----cut here----#
#!/bin/sh
# shar: Shell Archiver
# Run the following text with /bin/sh to create:
# diffs.1
# This archive created: Thu Dec 1 17:55:11 1988
cat << \SHAR_EOF > diffs.1
diff -bc2 alloc.c AmigaVersion:alloc.c
No differences encountered
diff -bc2 bones.c AmigaVersion:bones.c
*** bones.c Fri Jan 22 09:08:30 1988
--- AmigaVersion:bones.c Thu Aug 4 02:06:23 1988
***************
*** 4,7
#include "hack.h"
extern char plname[PL_NSIZ];
extern long somegold();
--- 4,8 -----
#include "hack.h"
+
extern char plname[PL_NSIZ];
extern long somegold();
***************
*** 95,99
}
#ifdef DGK
! fd = open(bones, O_WRONLY | O_BINARY | O_CREAT, FMASK);
#else
fd = creat(bones, FMASK);
--- 96,100 -----
}
#ifdef DGK
! fd = open(bones, O_WRONLY | O_BINARY | O_CREAT | O_TRUNC, FMASK);
#else
fd = creat(bones, FMASK);
***************
*** 111,114
savelev(fd,dlevel);
#endif
(void) close(fd);
}
--- 112,118 -----
savelev(fd,dlevel);
#endif
+ #ifdef COMPRESS
+ bflush(fd);
+ #endif
(void) close(fd);
}
***************
*** 162,165
}
#endif
getlev(fd, 0, dlevel);
for(x = 0; x < COLNO; x++) for(y = 0; y < ROWNO; y++)
--- 166,172 -----
}
#endif
+ #ifdef COMPRESS
+ minit();
+ #endif
getlev(fd, 0, dlevel);
for(x = 0; x < COLNO; x++) for(y = 0; y < ROWNO; y++) {
***************
*** 163,168
#endif
getlev(fd, 0, dlevel);
! for(x = 0; x < COLNO; x++) for(y = 0; y < ROWNO; y++)
! levl[x][y].seen = levl[x][y].new = 0;
}
(void) close(fd);
--- 170,178 -----
#endif
getlev(fd, 0, dlevel);
! for(x = 0; x < COLNO; x++) for(y = 0; y < ROWNO; y++) {
! /* levl[x][y].seen = levl[x][y].new = 0; */
! RM_CLR_SEEN(levl[x][y]);
! RM_CLR_NEW(levl[x][y]);
! }
}
(void) close(fd);
diff -bc2 config.h AmigaVersion:config.h
*** config.h Wed May 4 15:07:48 1988
--- AmigaVersion:config.h Tue Jul 26 14:39:54 1988
***************
*** 19,23
*/
#ifdef __MSDOS__ /* Turbo C auto-defines __MSDOS__, others MSDOS */
! /* # define MSDOS /* define for MS-DOS (actually defined by compiler) */
#endif
#define UNIX /* delete if no fork(), exec() available */
--- 19,23 -----
*/
#ifdef __MSDOS__ /* Turbo C auto-defines __MSDOS__, others MSDOS */
! # define MSDOS /* define for MS-DOS (actually defined by
compiler) */
#endif
#ifdef AMIGA
***************
*** 21,25
/* # define MSDOS /* define for MS-DOS (actually defined by compiler) */
#endif
! #define UNIX /* delete if no fork(), exec() available */
/* #define GENIX /* Yet Another Unix Clone */
#define BSD /* defind for 4.n BSD */
--- 21,28 -----
# define MSDOS /* define for MS-DOS (actually defined by
compiler) */
#endif
! #ifdef AMIGA
! # define MSDOS /* Also define for AMIGA */
! #endif
! /* #define UNIX /* delete if no fork(), exec() available */
/* #define GENIX /* Yet Another Unix Clone */
/* #define BSD /* define for 4.n BSD */
***************
*** 23,27
#define UNIX /* delete if no fork(), exec() available */
/* #define GENIX /* Yet Another Unix Clone */
! #define BSD /* defind for 4.n BSD */
/* #define SYSV /* define for System V */
/* #define NETWORK /* if running on a networked system */
--- 26,30 -----
/* #define UNIX /* delete if no fork(), exec() available */
/* #define GENIX /* Yet Another Unix Clone */
! /* #define BSD /* define for 4.n BSD */
/* #define SYSV /* define for System V */
/* #define NETWORK /* if running on a networked system */
***************
*** 30,34
#define VERSION "2.3e" /* version number. */
! #define PYRAMID_BUG /* avoid a bug on the Pyramid */
/* #define APOLLO /* same for the Apollo */
/* #define STUPID /* avoid some complicated expressions if
--- 33,37 -----
#define VERSION "2.3e" /* version number. */
! /* #define PYRAMID_BUG /* avoid a bug on the Pyramid */
/* #define APOLLO /* same for the Apollo */
/* #define STUPID /* avoid some complicated expressions if
***************
*** 41,46
#endif
! #define WIZARD "werner" /* the person allowed to use the -D option */
! #define RECORD "record"/* the file containing the list of topscorers */
#define NEWS "news" /* the file containing the latest hack news */
#define HELP "help" /* the file containing a description of the
commands */
--- 44,51 -----
#endif
! #ifndef WIZARD
! # define WIZARD "olaf" /* the person allowed to use the -D option */
! #endif
! #define RECORD "record" /* the file containing the list of topscorers
*/
#define NEWS "news" /* the file containing the latest hack news */
#define HELP "help" /* the file containing a description of the commands */
***************
*** 69,75
* A stat system call is done on the mailbox every MAILCKFREQ moves.
*/
! #define MAIL
! #define DEF_MAILREADER "/usr/bin/mail" /* or e.g. /bin/mail */
! #define MAILCKFREQ 1
--- 74,80 -----
* A stat system call is done on the mailbox every MAILCKFREQ moves.
*/
! /* #define MAIL
! /* #define DEF_MAILREADER "/usr/bin/mail" /* or e.g. /bin/mail */
! /* #define MAILCKFREQ 1 */
***************
*** 96,99
* If you define HACKDIR, then this will be the default playground;
* otherwise it will be the current directory.
*/
#define HACKDIR "/usr/games/lib/nethacklib"
--- 101,105 -----
* If you define HACKDIR, then this will be the default playground;
* otherwise it will be the current directory.
+ * Only matters when using unixmain.c
*/
#define HACKDIR "/usr/games/lib/nethacklib"
***************
*** 124,130
#define memcmp(s1, s2, n) bcmp(s2, s1, n)
#else
! #include <string.h> /* idem on System V */
! #define index strchr
! #define rindex strrchr
#endif
--- 130,139 -----
#define memcmp(s1, s2, n) bcmp(s2, s1, n)
#else
! /*#include <string.h> /* idem on System V */
! extern char *index(), *rindex();
! #define memcpy(d, s, n) movmem(s, d, n)
! #define memcmp(s1, s2, n) cmpmem(s2, s1, n)
! /*#define index strchr*/
! /*#define rindex strrchr*/
#endif
***************
*** 167,170
*/
#define Bitfield(x,n) uchar x
#define SIZE(x) (int)(sizeof(x) / sizeof(x[0]))
--- 176,182 -----
*/
#define Bitfield(x,n) uchar x
+ #ifdef AZTEC_C
+ # define BITFIELD_BUG /* So there. */
+ #endif
#define SIZE(x) (int)(sizeof(x) / sizeof(x[0]))
***************
*** 173,176
#include <fcntl.h>
#define exit msexit /* do chdir first */
#ifdef getchar
# undef getchar
--- 185,190 -----
#include <fcntl.h>
#define exit msexit /* do chdir first */
+ #define fopen fopenp /* using PATH */
+ extern FILE *fopenp();
#ifdef getchar
# undef getchar
***************
*** 175,180
#ifdef getchar
# undef getchar
! #endif /* getchar /**/
! #define getchar tgetch
#define DGK /* MS DOS specific enhancements by dgk */
--- 189,194 -----
#ifdef getchar
# undef getchar
! #endif /* getchar */
! #define getchar() tgetch()
#define DGK /* MS DOS specific enhancements by dgk */
***************
*** 228,231
#define STOOGES /* Three wild and crazy guys - Bruce Mewborne */
#define SINKS /* Kitchen sinks - Janet Walz */
#ifdef MSDOS
--- 242,246 -----
#define STOOGES /* Three wild and crazy guys - Bruce Mewborne */
#define SINKS /* Kitchen sinks - Janet Walz */
+ #define COMPRESS /* Zero-run compression of files - Olaf Seibert */
#ifdef MSDOS
diff -bc2 date.h AmigaVersion:date.h
*** date.h Fri Jan 22 09:28:44 1988
--- AmigaVersion:date.h Thu Aug 4 19:11:30 1988
***************
*** 1,3
/* SCCS Id: @(#)date.h 1.4 87/08/08 */
! char datestring[] = "Fri Jan 22 09:28:44 1988";
--- 1,3 -----
/* SCCS Id: @(#)date.h 1.4 87/08/08 */
! char datestring[] = "Thu Aug 4 19:11:48 1988";
diff -bc2 dog.c AmigaVersion:dog.c
No differences encountered
diff -bc2 dothrow.c AmigaVersion:dothrow.c
No differences encountered
diff -bc2 edog.h AmigaVersion:edog.h
No differences encountered
diff -bc2 eshk.h AmigaVersion:eshk.h
No differences encountered
diff -bc2 extern.h AmigaVersion:extern.h
No differences encountered
diff -bc2 flag.h AmigaVersion:flag.h
No differences encountered
diff -bc2 func_tab.h AmigaVersion:func_tab.h
No differences encountered
diff -bc2 gen.h AmigaVersion:gen.h
No differences encountered
diff -bc2 gold.h AmigaVersion:gold.h
No differences encountered
diff -bc2 hack.h AmigaVersion:hack.h
No differences encountered
diff -bc2 makedefs.c AmigaVersion:makedefs.c
*** makedefs.c Wed May 4 15:08:14 1988
--- AmigaVersion:makedefs.c Mon Jul 25 00:37:53 1988
***************
*** 8,16
#ifdef MSDOS
! #undef exit
! #define freopen _freopen
! #define alloc malloc
! #define RDMODE "r"
! #define WRMODE "w"
#else
#define RDMODE "r+"
--- 8,18 -----
#ifdef MSDOS
! # ifndef AMIGA
! # define freopen _freopen
! # endif
! # undef exit
! # define alloc malloc
! # define RDMODE "r"
! # define WRMODE "w"
#else
# define RDMODE "r+"
***************
*** 14,19
#define WRMODE "w"
#else
! #define RDMODE "r+"
! #define WRMODE "w+"
#endif
--- 16,21 -----
# define WRMODE "w"
#else
! # define RDMODE "r+"
! # define WRMODE "w+"
#endif
***************
*** 18,21
#endif
/* construct definitions of object constants */
#define OBJ_FILE "objects.h"
--- 20,35 -----
#endif
+ #ifdef AMIGA /* Get back normal stdio. Compiler dependent. */
+ # define stdin (&Cbuffs[0])
+ # define stdout (&Cbuffs[1])
+ # undef puts
+ # undef printf
+ # define remove(n) unlink(n)
+ #endif
+
+ #ifdef newobj
+ # undef newobj
+ #endif
+
/* construct definitions of object constants */
#define OBJ_FILE "objects.h"
***************
*** 134,139
exit(1);
}
! #ifdef MSDOS
! sprintf(infile, "%s.bas", RUMOR_FILE);
#else
sprintf(infile, "%s.base", RUMOR_FILE);
--- 148,153 -----
exit(1);
}
! #ifdef AMIGA
! sprintf(infile, "%s.base", RUMOR_FILE);
#else
# ifdef MSDOS
***************
*** 137,140
sprintf(infile, "%s.bas", RUMOR_FILE);
#else
sprintf(infile, "%s.base", RUMOR_FILE);
#endif
--- 151,157 -----
sprintf(infile, "%s.base", RUMOR_FILE);
#else
+ # ifdef MSDOS
+ sprintf(infile, "%s.bas", RUMOR_FILE);
+ # else
sprintf(infile, "%s.base", RUMOR_FILE);
# endif
***************
*** 138,141
#else
sprintf(infile, "%s.base", RUMOR_FILE);
#endif
if(freopen(infile, RDMODE, stdin) == NULL) {
--- 155,159 -----
# else
sprintf(infile, "%s.base", RUMOR_FILE);
+ # endif
#endif
if(freopen(infile, RDMODE, stdin) == NULL) {
***************
*** 218,221
while(gets(inline) != NULL) {
#ifdef KOPS
if(!strcmp(inline, "K a kobold"))
--- 236,243 -----
while(gets(inline) != NULL) {
+ /* note missing space v */
+ if (! strcmp(inline, "\ta dark part of a room"))
+ printf(" \ta dark part of a room\n");
+ else
#ifdef KOPS
if(!strcmp(inline, "K\ta kobold"))
***************
*** 219,223
while(gets(inline) != NULL) {
#ifdef KOPS
! if(!strcmp(inline, "K a kobold"))
printf("K\ta Keystone Kop\n");
else
--- 241,245 -----
else
#ifdef KOPS
! if(!strcmp(inline, "K\ta kobold"))
printf("K\ta Keystone Kop\n");
else
***************
*** 224,228
#endif
#ifdef KAA
! if(!strcmp(inline, "Q a quasit"))
printf("Q\ta quantum mechanic\n");
else
--- 246,250 -----
#endif
#ifdef KAA
! if(!strcmp(inline, "Q\ta quasit"))
printf("Q\ta quantum mechanic\n");
else
***************
*** 229,234
#endif
#ifdef ROCKMOLE
! if(!strcmp(inline, "r a giant rat"))
! printf("r\ta rockmole\n");
else
#endif
--- 251,256 -----
#endif
#ifdef ROCKMOLE
! if(!strcmp(inline, "r\ta giant rat"))
! printf("r\ta rockmole (or a giant rat)\n");
else
#endif
***************
*** 234,238
#endif
#ifdef SPIDERS
! if(!strcmp(inline, "s a scorpion"))
printf("s\ta giant spider\n");
else if (!strcmp(inline, "\" an amulet"))
--- 256,260 -----
#endif
#ifdef SPIDERS
! if(!strcmp(inline, "s\ta scorpion"))
printf("s\ta giant spider\n");
else if (!strcmp(inline, "\"\tan amulet"))
***************
*** 236,240
if(!strcmp(inline, "s a scorpion"))
printf("s\ta giant spider\n");
! else if (!strcmp(inline, "\" an amulet"))
printf("\"\tan amulet (or a web)\n");
else
--- 258,262 -----
if(!strcmp(inline, "s\ta scorpion"))
printf("s\ta giant spider\n");
! else if (!strcmp(inline, "\"\tan amulet"))
printf("\"\tan amulet (or a web)\n");
else
***************
*** 241,245
#endif
#ifdef SINKS
! if (!strcmp(inline, "# a corridor"))
printf("#\ta corridor (or a kitchen sink)\n");
else
--- 263,267 -----
#endif
#ifdef SINKS
! if (!strcmp(inline, "#\ta corridor"))
printf("#\ta corridor (or a kitchen sink)\n");
else
***************
*** 246,250
#endif
#ifdef SPELLS
! if (!strcmp(inline, "+ a door"))
printf("+\ta door (or a spell book)\n");
else
--- 268,272 -----
#endif
#ifdef SPELLS
! if (!strcmp(inline, "+\ta door"))
printf("+\ta door (or a spell book)\n");
else
***************
*** 251,255
#endif
#ifdef FOUNTAINS
! if(!strcmp(inline, "} water filled area")) {
puts(inline);
printf("{\ta fountain\n");
--- 273,277 -----
#endif
#ifdef FOUNTAINS
! if(!strcmp(inline, "}\twater filled area")) {
puts(inline);
printf("{\ta fountain\n");
***************
*** 257,261
#endif
#ifdef NEWCLASS
! if(!strcmp(inline, "^ a trap")) {
puts(inline);
printf("\\\tan opulent throne.\n");
--- 279,283 -----
#endif
#ifdef NEWCLASS
! if(!strcmp(inline, "^\ta trap")) {
puts(inline);
printf("\\\tan opulent throne.\n");
***************
*** 653,657
}
! #if defined(SYSV) || defined(GENIX)
rename(oldname, newname)
char *oldname, *newname;
--- 675,687 -----
}
! /* #if defined(SYSV) || defined(GENIX) */
! #ifdef SYSV
! # define XXX
! #endif
! #ifdef GENIX
! # define XXX
! #endif
!
! #ifdef XXX
rename(oldname, newname)
char *oldname, *newname;
***************
*** 665,668
}
#endif
#ifdef MSDOS
--- 695,699 -----
}
#endif
+ #undef XXX
#ifdef AMIGA
***************
*** 666,669
#endif
#ifdef MSDOS
/* Get around bug in freopen when opening for writing */
--- 697,704 -----
#undef XXX
+ #ifdef AMIGA
+ # undef MSDOS /* Watch out! */
+ #endif
+
#ifdef MSDOS
/* Get around bug in freopen when opening for writing */
***************
*** 695,696
# endif
#endif
--- 730,739 -----
# endif
#endif
+
+ #ifdef AMIGA
+ int getpid() {
+ return(1);
+ }
+ # endif
+
+
diff -bc2 mfndpos.h AmigaVersion:mfndpos.h
No differences encountered
diff -bc2 mkmaze.c AmigaVersion:mkmaze.c
*** mkmaze.c Wed May 4 15:08:22 1988
--- AmigaVersion:mkmaze.c Mon Jul 25 01:09:57 1988
***************
*** 19,23
for(x = 2; x < COLNO-1; x++)
for(y = 2; y < ROWNO-1; y++)
! levl[x][y].typ = (x%2 && y%2) ? 0 : HWALL;
#ifndef RPH
if(al) {
--- 19,23 -----
for(x = 2; x < COLNO-1; x++)
for(y = 2; y < ROWNO-1; y++)
! RM_SET_TYP(levl[x][y], (x%2 && y%2) ? 0 : HWALL);
#ifndef RPH
if(al) {
***************
*** 31,35
zy = 2*(ROWNO/4) - 1;
for(x = zx-2; x < zx+4; x++) for(y = zy-2; y <= zy+2; y++) {
! levl[x][y].typ =
(y == zy-2 || y == zy+2 || x == zx-2 || x == zx+3) ? POOL :
(y == zy-1 || y == zy+1 || x == zx-1 || x == zx+2) ? HWALL:
--- 31,35 -----
zy = 2*(ROWNO/4) - 1;
for(x = zx-2; x < zx+4; x++) for(y = zy-2; y <= zy+2; y++) {
! RM_SET_TYP(levl[x][y],
(y == zy-2 || y == zy+2 || x == zx-2 || x == zx+3) ? POOL :
(y == zy-1 || y == zy+1 || x == zx-1 || x == zx+2) ? HWALL:
***************
*** 34,38
(y == zy-2 || y == zy+2 || x == zx-2 || x == zx+3) ? POOL :
(y == zy-1 || y == zy+1 || x == zx-1 || x == zx+2) ? HWALL:
! ROOM;
}
#ifdef RPH
--- 34,38 -----
(y == zy-2 || y == zy+2 || x == zx-2 || x == zx+3) ? POOL :
(y == zy-1 || y == zy+1 || x == zx-1 || x == zx+2) ? HWALL:
! ROOM);
}
#ifdef RPH
***************
*** 74,78
for(x = 2; x < COLNO-1; x++)
for(y = 2; y < ROWNO-1; y++) {
! switch(levl[x][y].typ) {
case HWALL:
levl[x][y].scrsym = HWALL_SYM;
--- 74,78 -----
for(x = 2; x < COLNO-1; x++)
for(y = 2; y < ROWNO-1; y++) {
! switch(RM_TYP(levl[x][y])) {
case HWALL:
levl[x][y].scrsym = HWALL_SYM;
***************
*** 105,109
mazexy(&mm);
levl[(xupstair = mm.x)][(yupstair = mm.y)].scrsym = UP_SYM;
! levl[xupstair][yupstair].typ = STAIRS;
xdnstair = ydnstair = 0;
}
--- 105,109 -----
mazexy(&mm);
levl[(xupstair = mm.x)][(yupstair = mm.y)].scrsym = UP_SYM;
! RM_SET_TYP(levl[xupstair][yupstair], STAIRS);
xdnstair = ydnstair = 0;
}
***************
*** 129,133
x = (int) mazex[pos];
y = (int) mazey[pos];
! levl[x][y].typ = ROOM;
q = 0;
for (a = 0; a < 4; a++)
--- 129,133 -----
x = (int) mazex[pos];
y = (int) mazey[pos];
! RM_SET_TYP(levl[x][y], ROOM);
q = 0;
for (a = 0; a < 4; a++)
***************
*** 138,142
dir = dirs[rn2(q)];
move(&x, &y, dir);
! levl[x][y].typ = ROOM;
move(&x, &y, dir);
pos++;
--- 138,142 -----
dir = dirs[rn2(q)];
move(&x, &y, dir);
! RM_SET_TYP(levl[x][y], ROOM);
move(&x, &y, dir);
pos++;
***************
*** 153,157
register int q,a,dir;
int dirs[4];
! levl[x][y].typ = ROOM;
while(1) {
q = 0;
--- 153,157 -----
register int q,a,dir;
int dirs[4];
! RM_SET_TYP(levl[x][y], ROOM);
while(1) {
q = 0;
***************
*** 161,165
dir = dirs[rn2(q)];
move(&x,&y,dir);
! levl[x][y].typ = ROOM;
move(&x,&y,dir);
walkfrom(x,y);
--- 161,165 -----
dir = dirs[rn2(q)];
move(&x,&y,dir);
! RM_SET_TYP(levl[x][y], ROOM);
move(&x,&y,dir);
walkfrom(x,y);
***************
*** 186,190
move(&x,&y,dir);
move(&x,&y,dir);
! if(x<3 || y<3 || x>COLNO-3 || y>ROWNO-3 || levl[x][y].typ != 0)
return(0);
else
--- 186,190 -----
move(&x,&y,dir);
move(&x,&y,dir);
! if(x<3 || y<3 || x>COLNO-3 || y>ROWNO-3 || RM_TYP(levl[x][y]) != 0)
return(0);
else
diff -bc2 mkobj.c AmigaVersion:mkobj.c
*** mkobj.c Wed May 4 15:08:24 1988
--- AmigaVersion:mkobj.c Mon Jul 25 01:12:44 1988
***************
*** 96,101
otmp->otyp = otyp;
otmp->dknown = index(
! #ifdef KAA
! #ifdef SPELLS
"/=!?*+)",
#else
--- 96,101 -----
otmp->otyp = otyp;
otmp->dknown = index(
! #ifdef KAA /* Add ) */
! # ifdef SPELLS /* Add + */
"/=!?*+)",
# else
***************
*** 99,103
#ifdef SPELLS
"/=!?*+)",
! #else
"/=!?*)",
#endif
--- 99,103 -----
# ifdef SPELLS /* Add + */
"/=!?*+)",
! # else
"/=!?*)",
# endif
***************
*** 101,105
#else
"/=!?*)",
! #endif
#else
#ifdef SPELLS
--- 101,105 -----
# else
"/=!?*)",
! # endif
#else
# ifdef SPELLS
***************
*** 103,107
#endif
#else
! #ifdef SPELLS
"/=!?*+",
#else
--- 103,107 -----
# endif
#else
! # ifdef SPELLS
"/=!?*+",
# else
***************
*** 105,109
#ifdef SPELLS
"/=!?*+",
! #else
"/=!?*",
#endif
--- 105,109 -----
# ifdef SPELLS
"/=!?*+",
! # else
"/=!?*",
# endif
***************
*** 107,111
#else
"/=!?*",
! #endif
#endif
let) ? 0 : 1;
--- 107,111 -----
# else
"/=!?*",
! # endif
#endif
let) ? 0 : 1;
diff -bc2 mkroom.h AmigaVersion:mkroom.h
No differences encountered
diff -bc2 mkshop.c AmigaVersion:mkshop.c
*** mkshop.c Wed May 4 15:08:26 1988
--- AmigaVersion:mkshop.c Sat Jul 23 00:09:25 1988
***************
*** 204,208
sx = sroom->lx + (rn2(sroom->hx - sroom->lx));
sy = sroom->ly + (rn2(sroom->hy - sroom->ly));
! levl[sx][sy].typ = THRONE;
levl[sx][sy].scrsym = THRONE_SYM;
mkgold((long) rn1(50 * dlevel,10), sx, sy);
--- 204,208 -----
sx = sroom->lx + (rn2(sroom->hx - sroom->lx));
sy = sroom->ly + (rn2(sroom->hy - sroom->ly));
! RM_SET_TYP(levl[sx][sy], THRONE);
levl[sx][sy].scrsym = THRONE_SYM;
mkgold((long) rn1(50 * dlevel,10), sx, sy);
***************
*** 242,246
if((sx+sy)%2 && !o_at(sx,sy) && !t_at(sx,sy)
&& !m_at(sx,sy) && !nexttodoor(sx,sy)){
! levl[sx][sy].typ = POOL;
levl[sx][sy].scrsym = POOL_SYM;
if(!eelct || !rn2(4)) {
--- 242,246 -----
if((sx+sy)%2 && !o_at(sx,sy) && !t_at(sx,sy)
&& !m_at(sx,sy) && !nexttodoor(sx,sy)){
! RM_SET_TYP(levl[sx][sy], POOL);
levl[sx][sy].scrsym = POOL_SYM;
if(!eelct || !rn2(4)) {
***************
*** 259,264
register struct rm *lev;
for(dx = -1; dx <= 1; dx++) for(dy = -1; dy <= 1; dy++)
! if((lev = &levl[sx+dx][sy+dy])->typ == DOOR ||
! lev->typ == SDOOR || lev->typ == LDOOR)
return(TRUE);
return(FALSE);
--- 259,264 -----
register struct rm *lev;
for(dx = -1; dx <= 1; dx++) for(dy = -1; dy <= 1; dy++)
! if((lev = &levl[sx+dx][sy+dy]), RM_TYP(*lev) == DOOR ||
! RM_TYP(*lev) == SDOOR || RM_TYP(*lev) == LDOOR)
return(TRUE);
return(FALSE);
diff -bc2 monst.c AmigaVersion:monst.c
No differences encountered
diff -bc2 monst.h AmigaVersion:monst.h
No differences encountered
diff -bc2 msdos.h AmigaVersion:msdos.h
No differences encountered
diff -bc2 apply.c df1:apply.c
*** apply.c Wed May 4 15:07:42 1988
--- df1:apply.c Fri Jul 22 17:42:16 1988
***************
*** 218,222
}
lev = &levl[rx][ry];
! if(lev->typ == SDOOR) {
pline("You hear a hollow sound! This must be a secret door!");
lev->typ = DOOR;
--- 218,222 -----
}
lev = &levl[rx][ry];
! if(RM_TYP(*lev) == SDOOR) {
pline("You hear a hollow sound! This must be a secret door!");
RM_SET_TYP(*lev, DOOR);
***************
*** 220,224
if(lev->typ == SDOOR) {
pline("You hear a hollow sound! This must be a secret door!");
! lev->typ = DOOR;
atl(rx, ry, DOOR_SYM);
return(0);
--- 220,224 -----
if(RM_TYP(*lev) == SDOOR) {
pline("You hear a hollow sound! This must be a secret door!");
! RM_SET_TYP(*lev, DOOR);
atl(rx, ry, DOOR_SYM);
return(0);
***************
*** 224,228
return(0);
}
! if(lev->typ == SCORR) {
pline("You hear a hollow sound! This must be a secret
passage!");
lev->typ = CORR;
--- 224,228 -----
return(0);
}
! if(RM_TYP(*lev) == SCORR) {
pline("You hear a hollow sound! This must be a secret
passage!");
RM_SET_TYP(*lev, CORR);
***************
*** 226,230
if(lev->typ == SCORR) {
pline("You hear a hollow sound! This must be a secret
passage!");
! lev->typ = CORR;
atl(rx, ry, CORR_SYM);
return(0);
--- 226,230 -----
if(RM_TYP(*lev) == SCORR) {
pline("You hear a hollow sound! This must be a secret
passage!");
! RM_SET_TYP(*lev, CORR);
atl(rx, ry, CORR_SYM);
return(0);
***************
*** 323,327
if(mtmp = m_at(bchx,bchy))
break;
! if(!ZAP_POS(levl[bchx][bchy].typ)) {
bchx -= ddx;
bchy -= ddy;
--- 323,327 -----
if(mtmp = m_at(bchx,bchy))
break;
! if(!ZAP_POS(RM_TYP(levl[bchx][bchy]))) {
bchx -= ddx;
bchy -= ddy;
***************
*** 461,466
fracture_rock(obj);
digtxt = "The rock falls apart.";
! } else if(!lev->typ || lev->typ == SCORR) {
! lev->typ = CORR;
digtxt = "You succeeded in cutting away some rock.";
} else if(lev->typ == HWALL || lev->typ == VWALL
--- 461,466 -----
fracture_rock(obj);
digtxt = "The rock falls apart.";
! } else if(!RM_TYP(*lev) || RM_TYP(*lev) == SCORR) {
! RM_SET_TYP(*lev, CORR);
digtxt = "You succeeded in cutting away some rock.";
} else if(RM_TYP(*lev) == HWALL || RM_TYP(*lev) == VWALL
***************
*** 464,470
lev->typ = CORR;
digtxt = "You succeeded in cutting away some rock.";
! } else if(lev->typ == HWALL || lev->typ == VWALL
! || lev->typ == SDOOR) {
! lev->typ = xdnstair ? DOOR : ROOM;
digtxt = "You just made an opening in the wall.";
} else
--- 464,470 -----
RM_SET_TYP(*lev, CORR);
digtxt = "You succeeded in cutting away some rock.";
! } else if(RM_TYP(*lev) == HWALL || RM_TYP(*lev) == VWALL
! || RM_TYP(*lev) == SDOOR) {
! RM_SET_TYP(*lev, xdnstair ? DOOR : ROOM);
digtxt = "You just made an opening in the wall.";
} else
***************
*** 475,479
return(0);
} else {
! if(IS_WALL(levl[dpx][dpy].typ)) {
register int rno = inroom(dpx,dpy);
--- 475,479 -----
return(0);
} else {
! if(IS_WALL(RM_TYP(levl[dpx][dpy]))) {
register int rno = inroom(dpx,dpy);
***************
*** 569,573
ry = u.uy + u.dy;
if(u.dz > 0 || (u.dz == 0 && isok(rx, ry) &&
! (IS_ROCK(levl[rx][ry].typ)
|| sobj_at(ENORMOUS_ROCK, rx, ry))))
*dsp++ = *sdp;
--- 569,573 -----
ry = u.uy + u.dy;
if(u.dz > 0 || (u.dz == 0 && isok(rx, ry) &&
! (IS_ROCK(RM_TYP(levl[rx][ry]))
|| sobj_at(ENORMOUS_ROCK, rx, ry))))
*dsp++ = *sdp;
***************
*** 603,607
}
lev = &levl[rx][ry];
! if(lev->typ == DOOR)
pline("Your %s against the door.",
aobjnam(obj, "clang"));
--- 603,607 -----
}
lev = &levl[rx][ry];
! if (RM_TYP(*lev) == DOOR)
pline("Your %s against the door.",
aobjnam(obj, "clang"));
***************
*** 606,610
pline("Your %s against the door.",
aobjnam(obj, "clang"));
! else if(!IS_ROCK(lev->typ)
&& !sobj_at(ENORMOUS_ROCK, rx, ry)) {
/* ACCESSIBLE or POOL */
--- 606,610 -----
pline("Your %s against the door.",
aobjnam(obj, "clang"));
! else if(!IS_ROCK(RM_TYP(*lev))
&& !sobj_at(ENORMOUS_ROCK, rx, ry)) {
/* ACCESSIBLE or POOL */
diff -bc2 cmd.c df1:cmd.c
*** cmd.c Wed May 4 15:07:46 1988
--- df1:cmd.c Tue Jul 26 12:16:49 1988
***************
*** 131,135
struct func_tab cmdlist[]={
! #if defined(DGKMOD) && defined(DEBUG_DOESNT_WORK)
{'\004', /* ^D */ dodebug}, /* generic debug function */
#endif
--- 131,137 -----
struct func_tab cmdlist[]={
! /*#if defined(DGKMOD) && defined(DEBUG_DOESNT_WORK)*/
! #ifdef DKGMOD
! # ifdef DEBUG_DOESNT_WORK
{'\004', /* ^D */ dodebug}, /* generic debug function */
# endif
***************
*** 133,136
#if defined(DGKMOD) && defined(DEBUG_DOESNT_WORK)
{'\004', /* ^D */ dodebug}, /* generic debug function */
#endif
#ifdef WIZARD
--- 135,139 -----
# ifdef DEBUG_DOESNT_WORK
{'\004', /* ^D */ dodebug}, /* generic debug function */
+ # endif
#endif
***************
*** 134,137
{'\004', /* ^D */ dodebug}, /* generic debug function */
#endif
#ifdef WIZARD
{'\005', /* ^E */ wiz_detect},
--- 137,141 -----
# endif
#endif
+
#ifdef WIZARD
{'\005', /* ^E */ wiz_detect},
***************
*** 226,230
"dip", "dip an object into something", dodip,
#ifdef PRAYERS
! #ifdef THEOLOGY
"sacrifice", "offer a sacrifice to the gods", dosacrifice,
#endif
--- 230,234 -----
"dip", "dip an object into something", dodip,
#ifdef PRAYERS
! # ifdef THEOLOGY
"sacrifice", "offer a sacrifice to the gods", dosacrifice,
# endif
***************
*** 228,232
#ifdef THEOLOGY
"sacrifice", "offer a sacrifice to the gods", dosacrifice,
! #endif
"pray", "pray to the gods for help", dopray,
#endif
--- 232,236 -----
# ifdef THEOLOGY
"sacrifice", "offer a sacrifice to the gods", dosacrifice,
! # endif
"pray", "pray to the gods for help", dopray,
#endif
***************
*** 239,243
"turn", "turn undead", doturn,
#endif
! #if defined(KOPS) && defined(KAA)
"wipe", "wipe your face off", dowipe,
#endif
--- 243,249 -----
"turn", "turn undead", doturn,
#endif
! /* #if defined(KOPS) && defined(KAA) */
! #ifdef KOPS
! # ifdef KAA
"wipe", "wipe your face off", dowipe,
# endif
***************
*** 241,244
#if defined(KOPS) && defined(KAA)
"wipe", "wipe your face off", dowipe,
#endif
"?", "get this list of extended commands", doextlist,
--- 247,251 -----
# ifdef KAA
"wipe", "wipe your face off", dowipe,
+ # endif
#endif
"?", "get this list of extended commands", doextlist,
diff -bc2 decl.c df1:decl.c
*** decl.c Tue May 3 16:57:56 1988
--- df1:decl.c Fri Jul 22 19:50:05 1988
***************
*** 18,22
'"',
# endif
! #ifdef SINKS
'#',
#endif
--- 18,22 -----
'"',
# endif
! # ifdef SINKS
'#',
# endif
***************
*** 20,24
#ifdef SINKS
'#',
! #endif
};
--- 20,24 -----
# ifdef SINKS
'#',
! # endif
};
diff -bc2 do.c df1:do.c
*** do.c Wed May 4 15:07:50 1988
--- df1:do.c Wed Jul 27 23:42:55 1988
***************
*** 70,74
#endif
#ifdef SINKS
! if((obj->olet == RING_SYM) && IS_SINK(levl[u.ux][u.uy].typ))
if (u.uswallow) {
freeinv(obj);
--- 70,74 -----
#endif
#ifdef SINKS
! if((obj->olet == RING_SYM) && IS_SINK(RM_TYP(levl[u.ux][u.uy])))
if (u.uswallow) {
freeinv(obj);
***************
*** 203,206
#ifdef DGK
if (!savelev(fd, dlevel, COUNT)) {
(void) close(fd);
(void) unlink(lock);
--- 203,209 -----
#ifdef DGK
if (!savelev(fd, dlevel, COUNT)) {
+ # ifdef COMPRESS
+ bflush(fd);
+ # endif
(void) close(fd);
(void) unlink(lock);
***************
*** 222,225
#ifdef DGK
savelev(fd,dlevel, WRITE);
#else
--- 225,231 -----
#ifdef DGK
+ # ifdef COMPRESS
+ bflush(fd); /* Forget buffer */
+ # endif
savelev(fd,dlevel, WRITE);
#else
***************
*** 226,229
savelev(fd,dlevel);
#endif
(void) close(fd);
--- 232,238 -----
savelev(fd,dlevel);
#endif
+ #ifdef COMPRESS
+ bflush(fd); /* Flush buffer */
+ #endif
(void) close(fd);
***************
*** 256,259
done("tricked");
}
getlev(fd, hackpid, dlevel);
(void) close(fd);
--- 265,271 -----
done("tricked");
}
+ #ifdef COMPRESS
+ minit();
+ #endif
getlev(fd, hackpid, dlevel);
(void) close(fd);
***************
*** 298,302
u.ux = rnd(COLNO-1);
u.uy = rn2(ROWNO);
! } while(levl[u.ux][u.uy].typ != ROOM ||
m_at(u.ux,u.uy));
if(Punished){
--- 310,314 -----
u.ux = rnd(COLNO-1);
u.uy = rn2(ROWNO);
! } while(RM_TYP(levl[u.ux][u.uy]) != ROOM ||
m_at(u.ux,u.uy));
if(Punished){
***************
*** 328,332
}
! #if defined(KAA) && defined(KOPS)
wipeoff()
{
--- 340,346 -----
}
! /* #if defined(KAA) && defined(KOPS) */
! #ifdef KAA
! # ifdef KOPS
wipeoff()
{
***************
*** 351,355
{
if(u.ucreamed) {
! #ifdef DGKMOD
set_occupation(wipeoff, "wiping off your face", 0);
#else
--- 365,369 -----
{
if(u.ucreamed) {
! # ifdef DGKMOD
set_occupation(wipeoff, "wiping off your face", 0);
# else
***************
*** 353,357
#ifdef DGKMOD
set_occupation(wipeoff, "wiping off your face", 0);
! #else
occupation = wipeoff;
occtxt = "wiping off your face";
--- 367,371 -----
# ifdef DGKMOD
set_occupation(wipeoff, "wiping off your face", 0);
! # else
occupation = wipeoff;
occtxt = "wiping off your face";
***************
*** 356,360
occupation = wipeoff;
occtxt = "wiping off your face";
! #endif
return(1);
}
--- 370,374 -----
occupation = wipeoff;
occtxt = "wiping off your face";
! # endif
return(1);
}
***************
*** 362,366
return(1);
}
! #endif
/* split obj so that it gets size num */
--- 376,381 -----
return(1);
}
! # endif
! #endif /* KAA && KOPS */
/* split obj so that it gets size num */
diff -bc2 do_name.c df1:do_name.c
No differences encountered
diff -bc2 do_wear.c df1:do_wear.c
No differences encountered
diff -bc2 dogmove.c df1:dogmove.c
*** dogmove.c Fri Jan 22 09:08:32 1988
--- df1:dogmove.c Mon Jul 11 16:52:15 1988
***************
*** 156,160
return(0);
if(udist > 1){
! if(!IS_ROOM(levl[u.ux][u.uy].typ) || !rn2(4) ||
whappr ||
(mtmp->minvent && rn2((int) edog->apport)))
--- 156,160 -----
return(0);
if(udist > 1){
! if(!IS_ROOM(RM_TYP(levl[u.ux][u.uy])) || !rn2(4) ||
whappr ||
(mtmp->minvent && rn2((int) edog->apport)))
diff -bc2 eat.c df1:eat.c
No differences encountered
diff -bc2 end.c df1:end.c
*** end.c Wed May 4 15:07:58 1988
--- df1:end.c Mon Jul 25 15:36:45 1988
***************
*** 16,20
{
(void) signal(SIGINT,SIG_IGN);
! #if defined(WIZARD) && defined(UNIX) && !defined(KJSMODS)
if(wizard) {
pline("Dump core?");
--- 16,23 -----
{
(void) signal(SIGINT,SIG_IGN);
! /* #if defined(WIZARD) && defined(UNIX) && !defined(KJSMODS) */
! #ifdef WIZARD
! # ifdef UNIX
! # ifndef KJSMODS
if(wizard) {
pline("Dump core?");
***************
*** 24,27
}
}
#endif
pline("Really quit?");
--- 27,32 -----
}
}
+ # endif
+ # endif
#endif
pline("Really quit?");
***************
*** 96,99
dosave0(0);
#endif
fputs(" ERROR: ", stdout);
printf(str,a1,a2,a3,a4,a5,a6);
--- 101,107 -----
dosave0(0);
#endif
+ #ifdef stdout_puts /* For AMIGA */
+ stdout_puts(" ERROR: ");
+ #else
fputs(" ERROR: ", stdout);
#endif
***************
*** 97,100
#endif
fputs(" ERROR: ", stdout);
printf(str,a1,a2,a3,a4,a5,a6);
more(); /* contains a fflush() */
--- 105,109 -----
#else
fputs(" ERROR: ", stdout);
+ #endif
printf(str,a1,a2,a3,a4,a5,a6);
more(); /* contains a fflush() */
***************
*** 189,192
#endif
settty((char *) 0); /* does a clear_screen() */
if(!done_stopprint)
printf("Goodbye %s %s...\n\n", (Badged) ? "Officer" : pl_character,
plname);
--- 198,204 -----
#endif
settty((char *) 0); /* does a clear_screen() */
+ #ifdef AMIGA
+ curx = FAR;
+ #endif
if(!done_stopprint)
printf("Goodbye %s %s...\n\n", (Badged) ? "Officer" : pl_character,
plname);
***************
*** 294,298
cls();
}
! #ifdef MSDOSCOLOR
end_screen();
#endif
--- 306,310 -----
cls();
}
! /*#ifdef MSDOSCOLOR
end_screen();
#endif*/
***************
*** 296,300
#ifdef MSDOSCOLOR
end_screen();
! #endif
#ifdef WIZARD
if(!wizard)
--- 308,312 -----
/*#ifdef MSDOSCOLOR
end_screen();
! #endif*/
#ifdef WIZARD
if(!wizard)
diff -bc2 engrave.c df1:engrave.c
*** engrave.c Wed May 4 15:08:00 1988
--- df1:engrave.c Wed Aug 3 21:21:58 1988
***************
*** 525,528
save_engravings(fd) int fd; {
register struct engr *ep = head_engr;
while(ep) {
if(!ep->engr_lth || !ep->engr_txt[0]){
--- 525,529 -----
save_engravings(fd) int fd; {
register struct engr *ep = head_engr;
+ register struct engr *ep2;
while(ep) {
ep2 = ep->nxt_engr;
***************
*** 526,533
register struct engr *ep = head_engr;
while(ep) {
! if(!ep->engr_lth || !ep->engr_txt[0]){
! ep = ep->nxt_engr;
! continue;
! }
bwrite(fd, (char *) & (ep->engr_lth), sizeof(ep->engr_lth));
bwrite(fd, (char *) ep, sizeof(struct engr) + ep->engr_lth);
--- 527,532 -----
register struct engr *ep2;
while(ep) {
! ep2 = ep->nxt_engr;
! if(ep->engr_lth && ep->engr_txt[0]){
bwrite(fd, (char *) & (ep->engr_lth), sizeof(ep->engr_lth));
bwrite(fd, (char *) ep, sizeof(struct engr) + ep->engr_lth);
***************
*** 532,536
bwrite(fd, (char *) & (ep->engr_lth), sizeof(ep->engr_lth));
bwrite(fd, (char *) ep, sizeof(struct engr) + ep->engr_lth);
! ep = ep->nxt_engr;
}
bwrite(fd, (char *) nul, sizeof(unsigned));
--- 531,540 -----
bwrite(fd, (char *) & (ep->engr_lth), sizeof(ep->engr_lth));
bwrite(fd, (char *) ep, sizeof(struct engr) + ep->engr_lth);
! }
! #ifdef DGK
! if (!count_only)
! #endif
! free(ep);
! ep = ep2;
}
bwrite(fd, (char *) nul, sizeof(unsigned));
diff -bc2 fight.c df1:fight.c
*** fight.c Wed May 4 15:08:02 1988
--- df1:fight.c Fri Jul 22 20:54:20 1988
***************
*** 173,177
#endif
{
! #if defined(ROCKMOLE) && defined(KJSMODS)
/* if a giant rat is killed by a monster, do not make a
* corpse (like Keystone Kops above). */
--- 173,179 -----
#endif
{
! /* #if defined(ROCKMOLE) && defined(KJSMODS) */
! #ifdef ROCKMOLE
! # ifdef KJSMODS
/* if a giant rat is killed by a monster, do not make a
* corpse (like Keystone Kops above). */
***************
*** 177,180
* corpse (like Keystone Kops above). */
if(!(pd->mlet == 'r' && dlevel < 4))
#endif
if(!(pd->mlet == '&' && mdef->isdjinni)) /* no djinni corpse */
--- 179,183 -----
* corpse (like Keystone Kops above). */
if(!(pd->mlet == 'r' && dlevel < 4))
+ # endif
#endif
if(!(pd->mlet == '&' && mdef->isdjinni)) /* no djinni corpse */
diff -bc2 fountain.c df1:fountain.c
*** fountain.c Wed May 4 15:08:04 1988
--- df1:fountain.c Fri Jul 22 21:00:31 1988
***************
*** 10,16
* Implemented levitation bug fixes.
*
- * Revision 1.4.3 87/11/25 19:16:00 M. Stephenson
- * Implemented levitation bug fixes.
- *
* Revision 1.4.2 87/10/19 11:48:00 M. Stephenson
* Implementation of KJS bug fixes.
--- 10,13 -----
* Implemented levitation bug fixes.
*
* Revision 1.4.2 87/10/19 11:48:00 M. Stephenson
* Implementation of KJS bug fixes.
***************
*** 109,113
} while(nexttodoor(mx,my) || !((mx+my)%2) ||
(mx == u.ux && my == u.uy) ||
! (IS_POOL(levl[mx][my].typ)));
/* Put a pool at mx, my */
--- 106,110 -----
} while(nexttodoor(mx,my) || !((mx+my)%2) ||
(mx == u.ux && my == u.uy) ||
! (IS_POOL(RM_TYP(levl[mx][my]))));
/* Put a pool at mx, my */
***************
*** 113,117
/* Put a pool at mx, my */
! levl[mx][my].typ = POOL;
atl(mx,my,POOL_SYM);
madepool = 1;
--- 110,114 -----
/* Put a pool at mx, my */
! RM_SET_TYP(levl[mx][my], POOL);
atl(mx,my,POOL_SYM);
madepool = 1;
***************
*** 128,132
dryup(){
! if (!rn2(3) && (levl[u.ux][u.uy].typ == FOUNTAIN)) {
pline("The fountain dries up!");
levl[u.ux][u.uy].typ = ROOM;
--- 125,129 -----
dryup(){
! if (!rn2(3) && (RM_TYP(levl[u.ux][u.uy]) == FOUNTAIN)) {
pline("The fountain dries up!");
RM_SET_TYP(levl[u.ux][u.uy], ROOM);
***************
*** 130,134
if (!rn2(3) && (levl[u.ux][u.uy].typ == FOUNTAIN)) {
pline("The fountain dries up!");
! levl[u.ux][u.uy].typ = ROOM;
if(Invis) newsym(u.ux, u.uy);
}
--- 127,131 -----
if (!rn2(3) && (RM_TYP(levl[u.ux][u.uy]) == FOUNTAIN)) {
pline("The fountain dries up!");
! RM_SET_TYP(levl[u.ux][u.uy], ROOM);
if(Invis) newsym(u.ux, u.uy);
}
***************
*** 278,282
obj->cursed = 0;
obj->rustfree = 1;
! levl[u.ux][u.uy].typ = ROOM;
if(Invis) newsym(u.ux, u.uy);
return(0);
--- 275,279 -----
obj->cursed = 0;
obj->rustfree = 1;
! RM_SET_TYP(levl[u.ux][u.uy], ROOM);
if(Invis) newsym(u.ux, u.uy);
return(0);
diff -bc2 hack.c df1:hack.c
*** hack.c Wed May 4 15:08:06 1988
--- df1:hack.c Fri Jul 22 21:13:39 1988
***************
*** 36,40
if(!isok(x, y)) continue;
lev = &levl[x][y];
! if(!lev->lit && lev->scrsym == ROOM_SYM) {
lev->scrsym = STONE_SYM;
lev->new = 1;
--- 36,40 -----
if(!isok(x, y)) continue;
lev = &levl[x][y];
! if(!RM_LIT(*lev) && lev->scrsym == ROOM_SYM) {
lev->scrsym = STONE_SYM;
RM_SET_NEW(*lev);
***************
*** 38,42
if(!lev->lit && lev->scrsym == ROOM_SYM) {
lev->scrsym = STONE_SYM;
! lev->new = 1;
on_scr(x,y);
}
--- 38,42 -----
if(!RM_LIT(*lev) && lev->scrsym == ROOM_SYM) {
lev->scrsym = STONE_SYM;
! RM_SET_NEW(*lev);
on_scr(x,y);
}
***************
*** 76,81
if(!isok(x, y)) continue;
lev = &levl[x][y];
! if(!lev->lit && lev->scrsym == ROOM_SYM)
! lev->seen = 0;
}
}
--- 76,81 -----
if(!isok(x, y)) continue;
lev = &levl[x][y];
! if(!RM_LIT(*lev) && lev->scrsym == ROOM_SYM)
! RM_CLR_SEEN(*lev);
}
}
***************
*** 94,99
ry = u.uy+2*u.dy;
nomul(0);
! if(isok(rx,ry) && !IS_ROCK(levl[rx][ry].typ) &&
! (levl[rx][ry].typ != DOOR || !(u.dx && u.dy)) &&
!sobj_at(ENORMOUS_ROCK, rx, ry)) {
if((mtmp = m_at(rx,ry))) {
--- 94,99 -----
ry = u.uy+2*u.dy;
nomul(0);
! if(isok(rx,ry) && !IS_ROCK(RM_TYP(levl[rx][ry])) &&
! (RM_TYP(levl[rx][ry]) != DOOR || !(u.dx && u.dy)) &&
!sobj_at(ENORMOUS_ROCK, rx, ry)) {
if((mtmp = m_at(rx,ry))) {
***************
*** 118,123
continue;
}
! if(levl[rx][ry].typ == POOL) {
! levl[rx][ry].typ = ROOM;
mnewsym(rx,ry);
prl(rx,ry);
--- 118,123 -----
continue;
}
! if(RM_TYP(levl[rx][ry]) == POOL) {
! RM_SET_TYP(levl[rx][ry], ROOM);
mnewsym(rx,ry);
prl(rx,ry);
***************
*** 155,160
#endif
if((!invent || inv_weight()+90 <= 0) &&
! (!u.dx || !u.dy || (IS_ROCK(levl[u.ux][u.uy+u.dy].typ)
! &&
IS_ROCK(levl[u.ux+u.dx][u.uy].typ)))){
pline("However, you can squeeze yourself into a small
opening.");
break;
--- 155,160 -----
#endif
if((!invent || inv_weight()+90 <= 0) &&
! (!u.dx || !u.dy ||
(IS_ROCK(RM_TYP(levl[u.ux][u.uy+u.dy]))
! &&
IS_ROCK(RM_TYP(levl[u.ux+u.dx][u.uy]))))){
pline("However, you can squeeze yourself into a small
opening.");
break;
***************
*** 188,192
confdir();
} while(!isok(u.ux+u.dx, u.uy+u.dy) ||
! IS_ROCK(levl[u.ux+u.dx][u.uy+u.dy].typ));
}
if(!isok(u.ux+u.dx, u.uy+u.dy)){
--- 188,192 -----
confdir();
} while(!isok(u.ux+u.dx, u.uy+u.dy) ||
! IS_ROCK(RM_TYP(levl[u.ux+u.dx][u.uy+u.dy])));
SHAR_EOF
# End of shell archive
exit 0
--
Bob Page, U of Lowell CS Dept. page@swan.ulowell.edu ulowell!page
Have five nice days.